Adding Traces to a Lazy Monadic Evaluator
نویسندگان
چکیده
The debugging of lazy functional programs is a non yet satisfactorily solved problem. In recent years there have been several proposals for incorporating execution traces to lazy functional languages. In [CRW00], an extensive comparison of three of these systems can be found, namely Freja [NS97,Nil98], the Redex Trail System (RTS) [SR97a,SR97b] and Hood [Gil00]. They have been incorporated to different Haskell [JH99] compilers. Freja is a question-answer system that directs the programmer to the cause of an incorrect value. RTS allows the user to travel backwards from a value to the redex history leading to it. In Hood, the programmer first instruments the program marking the variables he wants to observe and then the system produces a printing of their final value. Final value is understood as the evaluation state of the variable at the point of observation.
منابع مشابه
An abstract machine for concurrent haskell with futures
We show how Sestoft’s abstract machine for lazy evaluation of purely functional programs can be extended to evaluate expressions of the calculus CHF – a process calculus that models Concurrent Haskell extended by imperative and implicit futures. The abstract machine is modularly constructed by first adding monadic IO-actions to the machine and then in a second step we add concurrency. Our main ...
متن کاملSymbolic Bayesian Inference
Bayesian inference, of posterior knowledge based on prior knowledge and observed evidence, is typically implemented by applying Bayes’s theorem, solving an equation in which the posterior multiplied by the probability of an observation equals a joint probability. But when we observe a value of a continuous variable, the observation usually has probability zero, and Bayes’s theorem says only tha...
متن کاملTransforming Functional Logic Programs into Monadic Functional Programs
We present a high-level transformation scheme to translate lazy functional logic programs into pure Haskell programs. This transformation is based on a recent proposal to efficiently implement lazy non-deterministic computations in Haskell in a monadic style. We build on this work and define a systematic method to transform lazy functional logic programs into monadic programs with explicit shar...
متن کاملEfficient Runtime Representation of Evaluation Transformers
This article outlines an efficient runtime representation of evaluation transformers. An evaluator space containing parameterised evaluators for structured and polymorphic types is introduced. Using this framework it is possible to handle runtime information about evaluators for arbitrary structured types as well as evaluation transformers for functions over polymorphic types. In future develop...
متن کاملA functional correspondence between monadic evaluators and abstract machines for languages with computational effects
We extend our correspondence between evaluators and abstract machines from the pure setting of the λ-calculus to the impure setting of the computational λ-calculus. We show how to derive new abstract machines from monadic evaluators for the computational λ-calculus. Starting from (1) a generic evaluator parameterized by a monad and (2) a monad specifying a computational effect, we inline the co...
متن کامل